;
(function () {

  'use strict';

  angular.module('directives.customActivity')
    .directive('summaryCheckingFile', summaryCheckingFile)
    .directive('summaryCheckingFileLayout', summaryCheckingFileLayout)
    .directive('summaryCheckingDiffLayout', summaryCheckingDiffLayout)
    .directive('summaryCheckingDiff', summaryCheckingDiff);

  function summaryCheckingFileLayout() {

    return {
      retrict: 'E',
      template: '<div layoutdom="4" draggable="true" class="model" module-name="summary-checking-file-layout">' +
      '<label class="title title-color2">各省对账文件未按时到达情况</label>' +
      '<div slider slider-include="summary-checking-file"></div>' +
      '</div>',
      replace: true
    };
  }

  function summaryCheckingFile(summaryCheckingFileService) {

    return {
      restrict: 'A',
      template: '<div class="center"></div><core-loading ng-hide="info.loading"></core-loading>',
      link: function (scope, element, attrs) {
        scope.info = summaryCheckingFileService;
        summaryCheckingFileService.queryBySys(attrs.summaryCheckingFile, element.find('div'));
      }
    }
  }

  summaryCheckingFile.$inject = ['summaryCheckingFileService'];

  function summaryCheckingDiffLayout() {

    return {
      retrict: 'E',
      template: '<div layoutdom="4" draggable="true" class="model" module-name="summary-checking-diff-layout">' +
      '<label class="title title-color2">各省对账差异率</label>' +
      '<div slider slider-include="summary-checking-diff"></div>' +
      '</div>',
      replace: true
    };
  }

  function summaryCheckingDiff(summaryCheckingDiffService) {

    return {
      restrict: 'A',
      template: '<div class="center"></div><core-loading ng-hide="info.loading"></core-loading>',
      link: function (scope, element, attrs) {
        scope.info = summaryCheckingDiffService;
        summaryCheckingDiffService.queryBySys(attrs.summaryCheckingDiff, element.find('div'));
      }
    }
  }

  summaryCheckingDiff.$inject = ['summaryCheckingDiffService'];
})();